#! /bin/bash
echo "===== Updating from SVN ====="
# svn update
cd src

echo
echo "===== Making JETI Version ====="
echo ">>> cleaning"
make clean
echo ">>>  making"
make EXT=JETI
echo ">>>  moving"
mv er9x.hex ../er9x-jeti.hex

echo
echo "===== Making FRSKY Version ====="
echo ">>> cleaning"
make clean
echo ">>>  making"
make EXT=FRSKY
echo ">>>  moving"
mv er9x.hex ../er9x-frsky.hex

echo
echo "===== Making ARDUPILOT Version ====="
echo ">>> cleaning"
make clean
echo ">>>  making"
make EXT=ARDUPILOT
echo ">>>  moving"
mv er9x.hex ../er9x-ardupilot.hex

echo
echo "===== Making MAIN Version ====="
echo ">>> cleaning"
make clean
echo ">>>  making"
make
echo ">>>  moving"
mv er9x.hex ../er9x.hex

echo ">>> cleaning"
make clean 
